package com.come4loves.game.dataconfig.model;

import com.come4loves.core.dataconfig.ModelAdapter;
import com.come4loves.core.dataconfig.annotation.DataFile;
import com.come4loves.game.module.card.constant.CardType;
import com.come4loves.game.module.card.constant.Quality;

@DataFile(fileName = "RandomShopConfig")
public class RandomShopConfig implements ModelAdapter {
	
	/**
	 * 卡牌id
	 */
	private int id;
	
	
	private int arenaType;
	

	private int cardType;
	
	/**
	 * 等级
	 */
	private int cId;
	
	/**
	 * 品质
	 */
	private int boxType;
	
	/**
	 * 卡牌权重
	 */
	private int weightCard;
	
	/**
	 * 宝箱权重
	 */
	private int weightBox;
	
	@Override
	public void initialize() {
	}

	public int getId() {
		return id;
	}

	public int getCardType() {
		return cardType;
	}

	
	public int getArenaType() {
		return arenaType;
	}

	public int getCid() {
		return cId;
	}

	public int getBoxType() {
		return boxType;
	}

	public int getWeightCard() {
		return weightCard;
	}

	public int getWeightBox() {
		return weightBox;
	}
	
	public int getWeight(boolean isBox) {
		if (isBox) {
			return weightBox;
		} else {
			return weightCard;
		}
	}

	public CardType geCardType() {
		return CardType.geCardType(cardType);
	}

	public Quality getQuality() {
		return Quality.getQualityType(boxType);
	}
	
}